<?php if (!defined('THINK_PATH')) exit();?><!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no">  
    <title>个人信息</title>
    <link rel="stylesheet" href="/Public/Home/css/member.css">
    <link rel="stylesheet" href="/Public/Home/js/calendar/mobiscroll.css" />
    <link rel="stylesheet" href="/Public/Home/js/calendar/mobiscroll_date.css" />
    <!--不识别数字为手机-->
<meta name="format-detection" content="telephone=no, email=no"/>
<!--通用js-->
<?php if(isset($signPackage) && !empty($signPackage)){ ?>
<script type="text/javascript" src="http://res.wx.qq.com/open/js/jweixin-1.2.0.js?v=201704270010"></script>
<?php } ?>
<script type="text/javascript" src="/Public/Home/js/require.js"></script>
<script type="text/javascript" src="/Public/Home/js/baseLoading.js?v=201705240001"></script>
<script src="/Public/Home/js/jquery.min.js" ></script>
<script src="/Public/Home/js/pincode-input.js" ></script>
<script src="/Public/Home/js/parabola.js" ></script>
<script src="/Public/Home/js/lazyload/jquery.lazyload.min.js"></script>
<script type="text/javascript">
    _global.isLogin = !!"<?php echo $wx_member_id; ?>";
	var isWxShareDiy = typeof yc_share_diy === "undefined" ? false : yc_share_diy;
	var yc_wx_shareImgPath = "";
	<?php if(isset($weixin_logo) && !empty($weixin_logo)){ ?>
		yc_wx_shareImgPath = "/Uploads/<?php echo ($weixin_logo["image"]); ?>";
	<?php } ?>
    var yc_pass_arr = {'local_id':"<?php echo I('local_id',1);?>",'top_local_id':"<?php echo I('top_local_id',1);?>"};
	if(parseInt(yc_pass_arr["local_id"]) == 21){
		_global.isStopSell = true;
	}
    <?php if(isset($signPackage) && !empty($signPackage)){ ?>
        _global.isWeiXinLoad = true;
        var isEnableLocation = typeof yc_wx_location === "undefined" ? false : yc_wx_location;
        var yc_wx_options = {
            "enableLocation" : isEnableLocation,
            "refuseCallback" : function(){},
            "mapCallback" : function(){},
            "config" : {
                debug: false,
                appId: '<?php echo $signPackage["appId"];?>',
                timestamp: '<?php echo $signPackage["timestamp"];?>',
                nonceStr: '<?php echo $signPackage["nonceStr"];?>',
                signature: '<?php echo $signPackage["signature"];?>',
                jsApiList: [
                    'checkJsApi'
                ]
            }
        };
        var isInHeader = typeof yc_wx_useInHeader === "undefined" ? true : yc_wx_useInHeader;
        if(isInHeader){
            wxAutoConfig(yc_wx_options);
        }
    <?php } ?>
</script>
</head>
<body>
	<div class="warp">
		<div class="member-info">
			<!-- 头像 -->
			<div class="head-bar">
                <div class="user-logo">
                    <input type="file" name="file" id="upImgBtn" />
                    <!-- 用户头像动态的 -->
                    <img id="user-logo-pic" class="img-lazyload" src="/Public/Home/images/member_headLogo.png" data-original="<?php echo ($user_top_img); ?>" />
                    <input id="usericon" type="hidden" value="<?php echo ($user_top_img); ?>">
                </div>
				<div class="account">
					<p><span><?php echo ($menber_data['nickname']); ?></span><span>2</span></p>
					<p><a href="<?php echo url('Login/alterMobileOne');?>"><?php echo ($menber_data['mobile']); ?></a></p>
				</div>
				<div class="address"><a href="<?php echo url('Member/memberAddress');?>">收货地址</a></div>
			</div>
			<!-- 个人信息 -->
			<div class="person-info">
				<h1 class="clearfix">个人信息<a href="javascript:void(0);" class="fr edit">编辑</a><a href="javascript:void(0);" class="fr complete" style="display:none;">完成</a></h1>
				<ul>
					<li><label>昵称：</label><input type="text" id="nickname" name="nickname" value="<?php echo ($menber_data['nickname']); ?>" disabled><a href="javascript:void(0);" class="clear"></a></li>
					<li><label>性别：</label><input type="text" id="sex" name="sex" value="<?php echo search(['女','男'],$menber_data['sex']);?>" disabled><a href="javascript:void(0);" class="clear"></a></li>
					<li><label>生日：</label><input type="text" id="birthday" name="age" value="<?php echo $menber_data['b_year'] ? $menber_data['b_year'].'-'.$menber_data['b_month'].'-'.$menber_data['b_day'] : '' ?>" disabled><a href="javascript:void(0);" class="clear"></a></li>
                    <li>
                        <label>身份证号：</label>
                        <span id="ycInfoIdNum" class="idcode"></span>
                        <?php if($menber_data['identity_verifi'] == '1'): ?><span class="idmsg succ">已审核</span>
                        <?php elseif($menber_data['identity_verifi'] == '3'): ?>
                            <span class="idmsg succ">审核中</span>
                        <?php elseif($menber_data['identity_verifi'] == '2'): ?>
                            <span id="ycIdUploadBtn" class="idmsg err">审核失败<br/>请重新上传</span><?php endif; ?>
                    </li>
				</ul>
			</div>
			<!-- 基本信息 -->
			<div class="basic-info">
				<h1 class="clearfix">基本信息</h1>
				<ul>
					<li>账号等级：<span><?php echo ($menber_data['lv_name']); ?></span></li>
					<li>账号特权：<span><?php echo ($menber_data['source2']); ?></span></li>
					<li>绑定手机：<span><?php echo ($menber_data['mobile']); ?></span></li>
					<li>默认地址：<span><?php echo ($menber_addr['addr']); ?></span></li>
				</ul>
			</div>
		</div>
    </div>
    <div class="alert-popup validate-tips">
        <p></p>
        <div class="single-show"><a href="javascript:void(0);" class="confirm">知道了</a></div>
    </div>
    <script type="text/javascript" src="/Public/Home/js/validate.js" ></script>
    <script type="text/javascript" src="/Public/Home/js/jquery.ajaxfileupload.js"></script>
    <script type="text/javascript" src="/Public/Home/js/calendar/mobiscroll_date.js"></script>
    <script type="text/javascript" src="/Public/Home/js/calendar/mobiscroll.js"></script>
    <script type="text/javascript">
        var currYear = (new Date()).getFullYear();
        var opt={};
        opt.date = {preset : 'date'};
        opt.datetime = {preset : 'datetime'};
        opt.time = {preset : 'time'};
        opt.default = {
            theme: 'android-ics light', //皮肤样式
            display: 'modal', //显示方式
            mode: 'scroller', //日期选择模式
            dateFormat: 'yyyy-mm-dd',
            lang: 'zh',
            showNow: true,
            nowText: "今天",
            startYear: currYear - 50, //开始年份
            endYear: currYear + 10 //结束年份
        };
        $("#birthday").mobiscroll($.extend(opt['date'], opt['default']));
		require(['member/info']);
	</script>
   <?php $isNeedId = false; $isValidIDInfo = true; $curIdNum = $menber_data['identity_card_num']; $curIdName = $menber_data['identity_name']; $curIdPhoto = $menber_data['identity_photo']; $curIdStatus = intval($menber_data['identity_verifi']); $sfyz_type = 0; if($curIdStatus == 2){ $sfyz_type = empty($curIdPhoto) ? 1 : 2; $isValidIDInfo = false; $isNeedId = true; } if($isNeedId){ $sfNeedJs = array('validate' => false, 'upload' => false); echo '<script type="text/javascript">'; echo 'var _ycIdData = {"yzType" : '.$sfyz_type.', "idNum" : "'.$curIdNum.'", "idName" : "'.$curIdName.'", "from" : "info"}'; echo '</script>'; ?>
    <link rel="stylesheet" href="/Public/Home/css/uploadIdentitly.css?v=20170306001">
<!-- 上传身份证弹窗 -->
<div class="upload-identity-frame" style="display: none;">
    <p class="identitly-title">
        <span>海淘实名认证</span>
        <a href="javascript:void(0)" class="close"></a>
    </p>
    <div class="upload-identity-content">
        <div class="upload-identity-ret">
            <p class="indetitly-tips">海关要求购买跨境商品需提供实名信息额</p>
            <input type="text" id="yc_sf_name" value="" placeholder="请输入真实姓名" />
            <input type="text" id="yc_sf_id" placeholder="第二代身份证号（将加密处理）"/>
            <div class="identitly-state">
                <p>请上传身份证正反面共两张图片</p>
                <div class="indetitly-cardimg">
                    <!--正面-->
                    <div class="upload-content-box">
                        <div class="upload-file-list frontpicImg"></div>
                        <i class="upload-btn" id="ycSfFrontBtn">
                            <span>正面</span>
                            <input id='ycSfFrontPic' type='hidden' value='' />      
                            <!-- <input id="ycSfFrontBtn" type="file" accept="image/*" name="file" /> -->
                        </i>
                    </div>
                    <!--反面-->
                    <div class="upload-content-box">
                        <div class="upload-file-list backpicImg"></div>
                        <i class="upload-btn" id="ycSfBackBtn">
                            <span>反面</span>
                            <input id='ycSfBackPic' type='hidden' value='' />                     
                            <!-- <input id="ycSfBackBtn" type="file" accept="image/*" name="file" /> -->
                        </i>
                    </div>
                </div>
                <p class="gray">温馨提示：请勿剪裁涂改照片，保证身份信息清晰显示，否则无法通过审核。</p>
            </div>
        </div>
        <div class="indetitly-mes">
            <h3>为什么需要实名认证？</h3>
            <p>根据海关要求，购买跨境商品需要对订购人进行实名认证，错误信息可能导致无法正常清关。</p>
            <p>你的身份证信息将加密保管，怡臣优选保证信息安全，绝不对外泄漏！</p>
            <p>任何身份认证可联系我们400-023-1666（09:00-18:00）</p>
        </div>
    </div>
    <div id="ycSfUpload" class="upload-submit btn btn-primary">确定</div>
</div>
<?php if(sfNeedJs["validate"]){ ?>
<script type="text/javascript" src="/Public/Home/js/validate.js"></script>
<?php } ?>
<script type="text/javascript" src="/Public/Home/js/cart/identitlyCard.js??v=201704270001"></script>
    <?php }else{ echo '<script type="text/javascript">'; echo '$("#ycInfoIdNum").html("'.$curIdNum.'")'; echo '</script>'; } ?>
</body>
</html>